package com.lwz.composite.component;

public abstract class Component {

	public String name;
	
	public Component(String name){
		this.name = name;
	}
	
	public  abstract void someOperation();
	
    public void addChild(Component child){
    	throw new UnsupportedOperationException("对象不支持这种功能");
          }
    
    public void removeChild(Component child){
    	throw new UnsupportedOperationException("对象不支持这种功能");
          }
    
    public Component getChild(int  index){
    	throw new UnsupportedOperationException("对象不支持这种功能");
          }
}
